using System;
using Neo.Generator.Core;
using Neo.MetaModel;

namespace Webbness.Module.VsTool
{
    [Serializable]
    public class ViewCodeGenerationContext : GenerationContext
    {
        private Entity entity;
        private ModelHelper helper;

        public ViewCodeGenerationContext(Entity anEntity)
        {
            entity = anEntity;
            helper = new ModelHelper(entity);
        }

        public Entity Entity
        {
            get { return entity; }
        }

        public string FileName
        {
            get { return (Entity.ClassName + ".boo"); }
        }

        public ModelHelper Helper
        {
            get { return helper; }
        }

        public override Model Model
        {
            get { return entity.Model; }
        }

        public string SupportFileName
        {
            get { return (Entity.ClassName + ".boo"); }
        }

        public override string ToString()
        {
            return "ViewCodeGenerationContext";
        }
    }
}